<!DOCTYPE html>
<html lang="zh-CN">
<head>
	<meta charset="utf-8">
	<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
	<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no">
	<meta http-equiv="content-language" content="zh-CN">
	<meta http-equiv="Cache-Control" content="no-transform"/>
	<meta http-equiv="Cache-Control" content="no-siteapp"/>
	<title>案例</title>
	<link rel="stylesheet" href="../skin/css/bootstrap.min.css">
	<!--[if lt IE 9]>
	<link rel="stylesheet" href="../skin/css/ie9/bootstrap.min.css">
	<![endif]-->
	<link rel="stylesheet" href="../skin/css/style.css">
	<script>var webroot = "/";</script>
	<!--[if lt IE 9]>
	<script src="http://cdn.bootcss.com/html5shiv/3.7.2/html5shiv.min.js"></script>
	<script src="http://cdn.bootcss.com/respond.js/1.4.2/respond.min.js"></script>
	<link rel="stylesheet" href="../skin/css/ie8.css">
	<![endif]-->
	<!--[if lt IE 8]>
	<meta http-equiv="refresh" content="0;url=/no-ie6.html"/>
	<![endif]-->

	<style>
		.btn-title{cursor: pointer}
	</style>
</head>
<body>
<!--head start-->
<header class="navbar navbar-default navbar-fixed-top" role="navigation">
	<div class="container">
		<!--mobile nav start-->
		<div class="navbar-header">
			<button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
				<span class="sr-only">Toggle navigation</span>
				<span class="icon-bar"></span>
				<span class="icon-bar"></span>
				<span class="icon-bar"></span>
			</button>
			<!--logo start-->
			<h1 class="logo"><a class="navbar-brand" href="/"></a>
				<small class="pull-left visible-lg-block visible-xs-block">四川腾达建筑设计有限公司</small>
			</h1>
		</div><!--end-->
		<!--nav start-->
		<nav class="collapse navbar-right navbar-collapse" role="navigation">
			<ul class="nav navbar-nav pull-left" id="nav">
				<li><a href="./index.html" class="">首页</a></li>
				<li><a href="./fuwuzhongxin.html">服务</a></li>
				<li><a href="./anni.html" class="hover">案例</a></li>
				<li><a href="./tuanduirenyuan.html" class="">团队</a></li>
				<li><a href="./news.html" class="">资讯</a></li>
				<li><a href="./guanyuwomen.html" class="">简介</a></li>
				<li><a href="./lianxiwomen.html" class="">联系</a>
					<ul class="list-unstyled"></ul>
				</li>
			</ul>
			<ul class=" list-unstyled nav-kj pull-right visible-md-block visible-lg-block">
				<li><a href="javascript:void(0)" class="fuwu">腾达客服</a>
					<div class="fuwu-nr">
						<h4>24小时在线服务</h4>
						<p>不论您遇到任何问题，装修服务或售后支持等<br>
							均可随时致电与我们沟通，我们会迅速为您解决问题</p>
						<hr class="small white">
						<h4>0818-2120958</h4>
						<p>sctdjzsj@foxmail.com</p>
					</div>
				</li>

				<li><a href="javascript:void(0)" class="sousuo">内容搜索</a>
					<div class="sousuo-nr">
						<input class="key" type="text" id="search-keyword" placeholder="请输入关键字">
						<input class="s-btn" type="button" value="搜">
					</div>
				</li>
			</ul>
		</nav><!--end-->
	</div>
</header>
<!--end-->
<section style="background-image:url(../skin/images/banner-case.jpg)" class="banner text-center full_bg">
	<div class="banner-mask">
		<div class="container">
			<h2>精雕细琢，精益求精</h2>
			<p>超过2000例客户选择了模板客，我们永远只做精品</p>
		</div>
	</div>
</section>

<main class="main">
	<div class="container">
		<!--menu-->
		<div class="ny-menu text-center">
			<ul class="list-inline news-class-parent">

			</ul>
		</div>
		<!--content start-->
		<section class="content">
			<div class="row case-box">

			</div>
			<div class="list-page">
				<ul class="pagination">

				</ul>
			</div>
		</section>
	</div>
</main>
﻿
<!--Action start-->
<section class="action text-center">
	<div class="container sx-jianju action-bg">
		<p>四川腾达建筑设计有限公司，成立于2002年4月<br class="hidden-xs"/>
			公司以“依法设计、诚实经营、周到服务、回馈社会”为宗旨<br class="hidden-xs"/>
			先进的设计理念、出色的创作水平、丰富的工作经验、严格的成本控制<br class="hidden-xs"/>
			立即致电 0818-2120958 或者通过以下方式联系。</p>
	</div>
</section><!--end-->
<!--footer start-->
<footer class="text-center">
	<div class="container">
		<div class="row footer">
			<figure class="col-xs-12 col-sm-4 col-md-4 col-lg-4">
				<span class="footer-dh"></span>
				<h3>电话</h3>
				<p>24小时服务热线<br/>0818-2120958</p>
			</figure>
			<figure class="col-xs-12 col-sm-4 col-md-4 col-lg-4">
				<span class="footer-dz"></span>
				<h3>地址</h3>
				<p>四川省达州市<br/>通川区白塔路243号</p>
			</figure>
			<figure class="col-xs-12 col-sm-4 col-md-4 col-lg-4">
				<span class="footer-yx"></span>
				<h3>腾达邮箱</h3>
				<p>email：<br/>sctdjzsj@foxmail.com</p>
			</figure>
		</div>
		<ul class="footer-nav list-inline menu-kj">
			<li><a href="./index.html">网站首页</a></li>
			<li><a href="./guanyuwomen.html">关于我们</a></li>
			<li><a href="./fuwuzhongxin.html">服务中心</a></li>
			<li><a href="./anni.html">成功案例</a></li>
			<li><a href="./news.html">公司新闻</a></li>
			<li><a href="./lianxiwomen.html">联系我们</a></li>
			<!--<li><a data-toggle="collapse" href="javascript:void(0)" data-target="#links" aria-expanded="false"
			       aria-controls="links">友情链接</a></li>-->
		</ul>
		<!--<div class="collapse" id="links">
			<div class="well">
				友情链接：{dede:flink row='24' type='text' titlelen='26' linktype = '2'}[field:link /] / {/dede:flink}
			</div>
		</div>-->
	</div>
	<div class="copy">
		<div class="container">
			<p>
				Copyright © 2002-2017 四川腾达建筑设计有限公司版权所有<br/>
				<a href="#" target="_blank">备案号：蜀ICP备17018019号-1</a></p>
		</div>
	</div>
</footer><!--end-->


<ul class="kefu">
	<li>
		<a href="#" class="kefu-top" data-toggle="tooltip" data-placement="left" id="top" title="回页面顶部" rel="nofollow">回顶部</a>
	</li>
</ul>
<!--jQuery-->
<script src="../skin/js/jquery.min.js"></script>
<script src="../skin/js/base.js"></script>
<script>$(function () {
	$("#h").addClass("hover");
})</script>
<script src="../skin/js/bootstrap.min.js"></script>
<script>$(function () {
	$("[data-toggle='tooltip']").tooltip();
})</script>
<script src="../skin/js/owl.carousel.min.js"></script>
<script src="../skin/js/owl.carousel.quote.js"></script>
<script>
	window._bd_share_config = {share: [{"tag": "HBD_FX", "bdSize": 32,}]}
	with (document)0[(getElementsByTagName('head')[0] || body).appendChild(createElement('script')).src = 'http://bdimg.share.baidu.com/static/api/js/share.js?cdnversion=' + ~(-new Date() / 36e5)];
</script>

<script src="../js/config.js"></script>
<script>
	$(function(){
		var _newsClass = null;
		var _onePageCount = 9
		/**
		 * 查询案例，初始化数据
		 */
		function initData(newsClass,count,page){
			_newsClass = newsClass
			$.ajax({
				type:'GET',
				url:host+"/news/page/class",
				data:{newsClass:newsClass,count:count,page:page},
				async:false,
				success:function (data) {
					if(data.code == 1){
						showAnniData(data)
					}
				},
				error: function(XMLHttpRequest){
					alert( "请求错误 " + XMLHttpRequest.responseText);
				}
			});

		}
		function showAnniData(data){
			console.log(data)
			var str = ``;
			for(var i = 0;i<data.list.length;i++){
				str += `<div class="col-xs-6 col-sm-6 col-md-4 col-lg-4">
							<figure><a href="./detail.html?id=${data.list[i].id}"><img src="${data.list[i].url}"  width="360" height="258"></a>
								<figcaption class="pic-hover">
									<h3><a href="./detail.html?id=${data.list[i].id}" >${data.list[i].title}</a></h3>
									<ul class="list-inline">
										<li>Category /</li>
										<li>${data.list[i].classname}</li>
									</ul>
									<span class="visible-lg-block visible-md-block"></span>
								</figcaption>
							</figure>
						</div>`
			}
			$(".case-box").empty();
			$(".case-box").append(str);
		}

		function setPage(newsClass,count){
			$.get(host+"/news/class/count",{newsClass:newsClass},function(data){
				if(data.code == 1){
					str = ``;
					$(".pagination").empty();
					var pageNum = Math.ceil(parseInt(data.msg)/count);
					for(var i = 1;i <= pageNum;i++){
						if (i == 1){
							str += `<li class="active p_item"><a>${i}</a></li>`
						}else {
							str += `<li class = "p_item"><a>${i}</a></li>`
						}
					}
					str += `<li><a>共${pageNum}页${data.msg}条</a></li>`;
					$(".pagination").append(str);
				}
			})
		}

		function changePage(){
			$(document).on("click",".p_item",function(){
				$.each($(".p_item"),function(i,item){
					$(item).removeClass("active")
				})
				$(this).addClass("active")
				initData(_newsClass,_onePageCount,$(this).text())

			})
		}

		/**
		 * 查询案例下的所有分类
		 */
		$.ajax({
			type:'GET',
			url:host+"/news/class/parent",
			data:{parentId:1},
			async:false,
			success:function (data) {
				if(data.code == 1){
					showNewClassParentData(data)
				}
			},
			error: function(XMLHttpRequest){
				alert( "请求错误 " + XMLHttpRequest.responseText);
			}
		});
		function showNewClassParentData(data){
			var str = ``;
			for(var i = 0;i<data.list.length;i++){
				str += `<li><a class="btn-title" data-id="${data.list[i].id}">${data.list[i].name}</a></li>`
			}
			$(".news-class-parent").empty();
			$(".news-class-parent").append(str);
		}

		/**
		 * 查询子类
		 */
		$(document).on("click",".btn-title",function(){
			$.each($(".btn-title"),function(i,item){
				$(item).css({
					'color': '#777',
					'border': '1px solid #ccc',
					'background':'#fff'
				})
			})
			$(this).css({
				'background-color': '#df3741',
				'border': '1px solid #df3741',
				'color': '#fff',
				'text-decoration': 'none'
			})
			var newsClass = $(this).attr("data-id");
			_newsClass = newsClass
			initData(_newsClass,_onePageCount,1)
			setPage(_newsClass,_onePageCount)
		})

		changePage()
		initData(2,_onePageCount,1)
		setPage(_newsClass,_onePageCount)
	})



</script>


</body>
</html>